// Calulate download speed
// Date 01:27 28/11/2016
// By Ben a.k.a DreamVB

#include <iostream>

using namespace std;
using std::cout;
using std::endl;

int main(int argc, char *argv[]){
	const int kb = 1024;
	double bits = 0.0;
	double kBitPerSec = 0.0;
	double KBytePerSec = 0.0;
	double gBitPerSec = 0.0;
	double mb = 0.0;
	double gb = 0.0;

	cout << "Enter number of mega bits per second : ";
	cin >> bits;
	cout << endl;

	//Get Kilobytes
	kBitPerSec = (bits*kb);
	gBitPerSec = (bits / kb);
	KBytePerSec = kBitPerSec / 8;;
	mb = (kBitPerSec / kb) / 8;
	gb = (mb / kb);

	cout << "Kilobit per sec   : " << kBitPerSec << endl;
	cout << "Megabit per sec   : " << bits << endl;
	cout << "Gigabit per sec   : " << gBitPerSec << endl;
	cout << "Kilobyte per sec  : " << KBytePerSec << endl;
	cout << "Megabyte per sec  : " << mb << endl;
	cout << "Gigabyte per sec  : " << gb << endl;

	system("pause");
	return 0;
}